import { post } from '@/utils/request'

// 查询快捷用语分组树列表
export const getKnowledgeGroupTreeList = p => post(`/service-cop/b/msgKnowledge/v1/knowledgeGroupTreeList/${p.parentId}`, p)
// 查询快捷用语分组列表
export const getKnowledgeGroupList = p => post(`/service-cop/b/msgKnowledge/v1/knowledgeGroupList`, p)
// 查询快捷用语分组详情
export const viewKnowledgeGroup = p => post(`/service-cop/b/msgKnowledge/v1/knowledgeGroupView/${p.id}`, p, 'get')
// 添加快捷用语分组
export const addKnowledgeGroup = p => post(`/service-cop/b/msgKnowledge/v1/knowledgeGroupAdd`, p)
// 修改快捷用语分组
export const modifyKnowledgeGroup = p => post(`/service-cop/b/msgKnowledge/v1/knowledgeGroupModify`, p)
// 删除快捷用语分组
export const delKnowledgeGroup = p => post(`/service-cop/b/msgKnowledge/v1/knowledgeGroupDel/${p.id}`, p, 'get')

// 查询快捷用语分页列表
export const getKnowledgePageList = p => post(`/service-cop/b/msgKnowledge/v1/knowledgeList`, p)
// 查询快捷用语详情
export const viewKnowledge = p => post(`/service-cop/b/msgKnowledge/v1/knowledgeView/${p.id}`, p, 'get')
// 添加快捷用语
export const addKnowledge = p => post(`/service-cop/b/msgKnowledge/v1/knowledgeAdd`, p)
// 修改快捷用语
export const modifyKnowledge = p => post(`/service-cop/b/msgKnowledge/v1/knowledgeModify`, p)
// 删除快捷用语
export const delKnowledge = p => post(`/service-cop/b/msgKnowledge/v1/knowledgeDel/${p.id}`, p, 'get')
// 删除快捷用语
export const changeKnowledgeStatus = p => post(`/service-cop/b/msgKnowledge/v1/changeKnowledgeStatus/${p.id}/${p.status}`, p, 'get')

// 查询群发消息分页列表 /service-cop/b/friends/v1/pageList
export const getMassMessagePageList = p => post(`/service-cop/b/msgMassMessage/v1/list`, p)
// 查询群发消息详情
export const viewMassMessage = p => post(`/service-cop/b/msgMassMessage/v1/view/${p.id}`, p, 'get')
// 添加群发消息
export const addMassMessage = p => post(`/service-cop/b/msgMassMessage/v1/add`, p)
// 修改群发消息
export const modifyMassMessage = p => post(`/service-cop/b/msgMassMessage/v1/modify`, p)
// 复制群发消息
export const copyMassMessage = p => post(`/service-cop/b/msgMassMessage/v1/copy/${p.id}`, p)
// 删除群发消息
export const delMassMessage = p => post(`/service-cop/b/msgMassMessage/v1/del/${p.id}`, p, 'get')
// 统计客户数
export const summaryReceiverTotal = p => post(`/service-cop/b/msgMassMessage/v1/summaryReceiverTotal`, p)
// 提交消息发送任务
export const sendWxCpMassMessage = p => post(`/service-cop/b/msgMassMessage/v1/sendWxCpMassMessage/${p.id}`, p)
// 取消消息发送任务
export const stopWxCpMassMessage = p => post(`/service-cop/b/msgMassMessage/v1/stopWxCpMassMessage/${p.id}`, p)
// 刷新消息发布记录
export const refreshWxCpMassMessageSendRecord = p => post(`/service-cop/b/msgFansMoment/v1/refreshWxCpMassMessageSendRecord`, p)

// 查询客户群发消息分页列表 /service-cop/b/friends/v1/pageList
export const getGroupMassMessagePageList = p => post(`/service-cop/b/msgGroupMassMessage/v1/list`, p)
// 查询客户群发消息详情
export const viewGroupMassMessage = p => post(`/service-cop/b/msgGroupMassMessage/v1/view/${p.id}`, p, 'get')
// 添加客户群发消息
export const addGroupMassMessage = p => post(`/service-cop/b/msgGroupMassMessage/v1/add`, p)
// 修改客户群发消息
export const modifyGroupMassMessage = p => post(`/service-cop/b/msgGroupMassMessage/v1/modify`, p)
// 复制群发消息
export const copyGroupMassMessage = p => post(`/service-cop/b/msgGroupMassMessage/v1/copy/${p.id}`, p)
// 删除客户群发消息
export const delGroupMassMessage = p => post(`/service-cop/b/msgGroupMassMessage/v1/del/${p.id}`, p, 'get')
// 提交消息发送任务
export const sendWxCpGroupMassMessage = p => post(`/service-cop/b/msgGroupMassMessage/v1/sendWxCpGroupMassMessage/${p.id}`, p)
// 取消消息发送任务
export const stopWxCppGroupMassMessage = p => post(`/service-cop/b/msgGroupMassMessage/v1/stopWxCppGroupMassMessage/${p.id}`, p)
// 刷新消息发布记录
export const refreshWxCpGroupMassMessageSendRecord = p => post(`/service-cop/b/msgFansMoment/v1/refreshWxCpGroupMassMessageSendRecord`, p)

// 查询朋友圈信息分页列表 /service-cop/b/friends/v1/pageList
export const getFansMomentPageList = p => post(`/service-cop/b/msgFansMoment/v1/list`, p)
// 查询朋友圈信息详情
export const viewFansMoment = p => post(`/service-cop/b/msgFansMoment/v1/view/${p.id}`, p, 'get')
// 添加朋友圈信息
export const addFansMoment = p => post(`/service-cop/b/msgFansMoment/v1/add`, p)
// 修改朋友圈信息
export const modifyFansMoment = p => post(`/service-cop/b/msgFansMoment/v1/modify`, p)
// 复制群发消息
export const copyFansMoment = p => post(`/service-cop/b/msgFansMoment/v1/copy/${p.id}`, p)
// 删除朋友圈信息
export const delFansMoment = p => post(`/service-cop/b/msgFansMoment/v1/del/${p.id}`, p, 'get')
// 提交朋友圈发送任务
export const sendWxCpFansMoment = p => post(`/service-cop/b/msgFansMoment/v1/sendWxCpFansMoment/${p.id}`, p)
// 取消朋友圈发送任务
export const stopWxCpFansMoment = p => post(`/service-cop/b/msgFansMoment/v1/stopWxCpFansMoment/${p.id}`, p)
// 刷新朋友圈发布记录
export const refreshWxCpFansMomentPublishRecord = p => post(`/service-cop/b/msgFansMoment/v1/refreshWxCpFansMomentPublishRecord`, p)

// 查询群发SOP分页列表
export const getMessageSopPageList = p => post(`/service-cop/b/msgMessageSop/v1/pageList`, p)
// 查询群发SOP列表
export const getMessageSopList = p => post(`/service-cop/b/msgMessageSop/v1/list`, p)
// 查询群发SOP信息详情
export const viewMessageSop = p => post(`/service-cop/b/msgMessageSop/v1/view/${p.id}`, p, 'get')
// 添加群发SOP信息
export const addMessageSop = p => post(`/service-cop/b/msgMessageSop/v1/add`, p)
// 修改群发SOP信息
export const modifyMessageSop = p => post(`/service-cop/b/msgMessageSop/v1/modify`, p)
// 删除群发SOP信息
export const delMessageSop = p => post(`/service-cop/b/msgMessageSop/v1/del/${p.id}`, p, 'get')

// 查询朋友圈SOP分页列表
export const getFansMomentSopPageList = p => post(`/service-cop/b/msgFansMomentSop/v1/pageList`, p)
// 查询朋友圈SOP列表
export const getFansMomentSopList = p => post(`/service-cop/b/msgFansMomentSop/v1/list`, p)
// 查询朋友圈SOP信息详情
export const viewFansMomentSop = p => post(`/service-cop/b/msgFansMomentSop/v1/view/${p.id}`, p, 'get')
// 添加朋友圈SOP信息
export const addFansMomentSop = p => post(`/service-cop/b/msgFansMomentSop/v1/add`, p)
// 修改朋友圈SOP信息
export const modifyFansMomentSop = p => post(`/service-cop/b/msgFansMomentSop/v1/modify`, p)
// 删除朋友圈SOP信息
export const delFansMomentSop = p => post(`/service-cop/b/msgFansMomentSop/v1/del/${p.id}`, p, 'get')
